package com.yishu.shop.controller;

import com.yishu.shop.service.OrderService;
import com.ys.commons.model.JsonResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * todo
 *
 * @author zengchao
 * @date 2021-07-14 20:58:26
 */
@RestController
@RequestMapping("order")
public class OrderController {
    @Autowired
    private OrderService orderService;

    @GetMapping()
    public JsonResponse<Object> getOrderInfo(@RequestParam("orderNo")String orderNo){
        Object orderInfo = orderService.getOrderInfo(orderNo);
        return JsonResponse.ok(orderInfo);
    }
}
